//
//  TSLabelCollectionHeaderView.swift
//  Picture
//
//  Created by 王磊 on 28/04/2017.
//  Copyright © 2017 ThreeStone. All rights reserved.
//

import UIKit

class TSLabelCollectionHeaderView: UICollectionReusableView {
    
    private var textLabel: UILabel = UILabel()
    
    override init(frame: CGRect) {
        super.init(frame: frame)
        
        commitInitOwnProperties()
        
        ts_configOwnSubviews()
    }
    
    required init?(coder aDecoder: NSCoder) {
        fatalError("init(coder:) has not been implemented")
    }
}
extension TSLabelCollectionHeaderView {
    internal func commitInitOwnProperties() {
        
        backgroundColor = UIColor.clearColor()
        
    }
    
    internal func ts_configOwnSubviews() {
        
        addSubview(textLabel)
        
        textLabel.text = "选择需要展示的类别"
        
        textLabel.textAlignment =  .Left
    }
}
extension TSLabelCollectionHeaderView {
    
}

extension TSLabelCollectionHeaderView {
    
    override func layoutSubviews() {
        super.layoutSubviews()
        
        textLabel.frame = CGRectMake(Label_Section_Header_Label_Left_Margin, 0, CGRectGetWidth(bounds), CGRectGetHeight(bounds))
        
    }
}
